import { useState } from 'react'
import logo from './logo.svg'
import './App.css'

function App() {
  const [name,setName] = useState(0);
  const [age,setAge] = useState(0);
  const [sex,setSex] = useState(0);

  function click() {

    console.log('name:',name,'age:',age,'sex:',sex);
    setName(name+1);
    console.log('name:',name,'age:',age,'sex:',sex);
    setAge(age+1);
    console.log('name:',name,'age:',age,'sex:',sex);

  }

  return (
    <div className="App">
      <button onClick={click}>button</button>
    </div>
  )
}

export default App
